<!DOCTYPE html>
<html lang="zh-CN">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>我的课程 - GitHub深色风格</title>
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
    <style>
        :root {
            --bg-primary: #0d1117;
            --bg-secondary: #161b22;
            --bg-tertiary: #21262d;
            --text-primary: #f0f6fc;
            --text-secondary: #c9d1d9;
            --text-tertiary: #8b949e;
            --border-color: #30363d;
            --accent-color: #58a6ff;
            --success-color: #3fb950;
            --warning-color: #d29922;
            --danger-color: #f85149;
            --border-radius: 6px;
            --shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
        }

        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
            font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
        }

        body {
            background-color: var(--bg-primary);
            color: var(--text-primary);
            line-height: 1.5;
        }

        .container {
            max-width: 1280px;
            margin: 0 auto;
            padding: 0 20px;
        }

        /* 导航栏样式 */
        header {
            background-color: var(--bg-secondary);
            border-bottom: 1px solid var(--border-color);
            position: sticky;
            top: 0;
            z-index: 100;
        }

        .navbar {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 16px 0;
        }

        .logo {
            font-size: 24px;
            font-weight: 700;
            color: var(--text-primary);
            text-decoration: none;
            display: flex;
            align-items: center;
        }

        .logo i {
            margin-right: 10px;
            color: var(--accent-color);
        }

        .nav-links {
            display: flex;
            gap: 24px;
        }

        .nav-links a {
            color: var(--text-secondary);
            text-decoration: none;
            font-size: 14px;
            transition: color 0.2s;
        }

        .nav-links a:hover,
        .nav-links a.active {
            color: var(--text-primary);
        }

        .user-menu {
            display: flex;
            align-items: center;
            gap: 16px;
        }

        .search-box {
            position: relative;
        }

        .search-box input {
            background-color: var(--bg-tertiary);
            border: 1px solid var(--border-color);
            border-radius: var(--border-radius);
            padding: 8px 12px;
            padding-left: 32px;
            color: var(--text-primary);
            width: 240px;
            font-size: 14px;
        }

        .search-box i {
            position: absolute;
            left: 10px;
            top: 50%;
            transform: translateY(-50%);
            color: var(--text-tertiary);
        }

        .user-avatar {
            width: 32px;
            height: 32px;
            border-radius: 50%;
            background-color: var(--accent-color);
            display: flex;
            align-items: center;
            justify-content: center;
            font-weight: bold;
            cursor: pointer;
        }

        /* 页面标题和筛选器 */
        .page-header {
            margin: 32px 0 24px;
            display: flex;
            justify-content: space-between;
            align-items: center;
        }

        .page-title {
            font-size: 24px;
            font-weight: 600;
        }

        .filters {
            display: flex;
            gap: 12px;
        }

        .filter-btn {
            background-color: var(--bg-secondary);
            border: 1px solid var(--border-color);
            border-radius: var(--border-radius);
            padding: 8px 16px;
            color: var(--text-secondary);
            font-size: 14px;
            cursor: pointer;
            transition: all 0.2s;
        }

        .filter-btn:hover {
            background-color: var(--bg-tertiary);
            border-color: var(--text-tertiary);
        }

        .filter-btn.active {
            background-color: var(--accent-color);
            border-color: var(--accent-color);
            color: white;
        }

        /* 课程网格 */
        .courses-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
            gap: 24px;
            margin-bottom: 40px;
        }

        .course-card {
            background-color: var(--bg-secondary);
            border: 1px solid var(--border-color);
            border-radius: var(--border-radius);
            overflow: hidden;
            transition: transform 0.2s, box-shadow 0.2s;
        }

        .course-card:hover {
            transform: translateY(-4px);
            box-shadow: var(--shadow);
        }

        .course-image {
            height: 160px;
            background-color: var(--bg-tertiary);
            position: relative;
            overflow: hidden;
        }

        .course-image img {
            width: 100%;
            height: 100%;
            object-fit: cover;
        }

        .course-category {
            position: absolute;
            top: 12px;
            left: 12px;
            background-color: rgba(13, 17, 23, 0.8);
            color: var(--text-secondary);
            padding: 4px 8px;
            border-radius: 4px;
            font-size: 12px;
        }

        .course-progress {
            position: absolute;
            bottom: 0;
            left: 0;
            width: 100%;
            height: 4px;
            background-color: var(--bg-tertiary);
        }

        .progress-bar {
            height: 100%;
            background-color: var(--success-color);
        }

        .course-content {
            padding: 16px;
        }

        .course-title {
            font-size: 18px;
            font-weight: 600;
            margin-bottom: 8px;
            color: var(--text-primary);
        }

        .course-description {
            color: var(--text-secondary);
            font-size: 14px;
            margin-bottom: 16px;
            display: -webkit-box;
            -webkit-line-clamp: 2;
            line-clamp: 1;
            -webkit-box-orient: vertical;
            overflow: hidden;
        }

        .course-meta {
            display: flex;
            justify-content: space-between;
            color: var(--text-tertiary);
            font-size: 12px;
            margin-bottom: 16px;
        }

        .course-actions {
            display: flex;
            gap: 8px;
        }

        .btn {
            padding: 8px 16px;
            border-radius: var(--border-radius);
            font-size: 14px;
            font-weight: 500;
            cursor: pointer;
            border: none;
            transition: all 0.2s;
            flex: 1;
            text-align: center;
            text-decoration: none;
        }

        .btn-primary {
            background-color: var(--accent-color);
            color: white;
        }

        .btn-primary:hover {
            background-color: #4a93e0;
        }

        .btn-secondary {
            background-color: var(--bg-tertiary);
            color: var(--text-primary);
            border: 1px solid var(--border-color);
        }

        .btn-secondary:hover {
            background-color: var(--bg-secondary);
        }

        /* 空状态 */
        .empty-state {
            text-align: center;
            padding: 60px 20px;
            color: var(--text-tertiary);
        }

        .empty-state i {
            font-size: 64px;
            margin-bottom: 16px;
            opacity: 0.5;
        }

        .empty-state h3 {
            font-size: 20px;
            margin-bottom: 8px;
            color: var(--text-secondary);
        }

        /* 页脚 */
        footer {
            border-top: 1px solid var(--border-color);
            padding: 24px 0;
            margin-top: 40px;
            text-align: center;
            color: var(--text-tertiary);
            font-size: 14px;
        }

        /* 响应式设计 */
        @media (max-width: 768px) {
            .navbar {
                flex-direction: column;
                gap: 16px;
            }

            .nav-links {
                order: 3;
                width: 100%;
                justify-content: center;
            }

            .search-box input {
                width: 200px;
            }

            .page-header {
                flex-direction: column;
                align-items: flex-start;
                gap: 16px;
            }

            .filters {
                flex-wrap: wrap;
            }

            .courses-grid {
                grid-template-columns: 1fr;
            }
        }
    </style>
</head>

<body>
    <!-- 导航栏 -->
    <header>
        <div class="container">
            <nav class="navbar">
                <a href="index.html" class="logo">
                    <i class="fas fa-graduation-cap"></i>
                    StudyRaid
                </a>

                <div class="nav-links">
                    <a href="my-courses.html" class="active">我的课程</a>
                    <a href="explore.html">发现</a>
                    <a href="learning-path.html">学习路径</a>
                    <a href="progress-tracking.html">进度追踪</a>
                </div>

                <div class="user-menu">
                    <div class="search-box">
                        <i class="fas fa-search"></i>
                        <input type="text" placeholder="搜索课程...">
                    </div>
                    <div class="user-avatar">JS</div>
                </div>
            </nav>
        </div>
    </header>

    <!-- 主要内容 -->
    <main class="container">
        <div class="page-header">
            <h1 class="page-title">我的课程</h1>
            <div class="filters">
                <button class="filter-btn active">全部</button>
                <button class="filter-btn">进行中</button>
                <button class="filter-btn">已完成</button>
                <button class="filter-btn">已收藏</button>
            </div>
        </div>

        <!-- 课程网格 -->
        <div class="courses-grid">
            <!-- 课程卡片 1 -->
            <div class="course-card">
                <div class="course-image">
                    <img src="https://placehold.co/300x160/21262d/8b949e?text=JavaScript" alt="JavaScript 高级编程">
                    <div class="course-category">前端开发</div>
                    <div class="course-progress">
                        <div class="progress-bar" style="width: 65%"></div>
                    </div>
                </div>
                <div class="course-content">
                    <h3 class="course-title">JavaScript 高级编程</h3>
                    <p class="course-description">深入学习现代JavaScript，包括ES6+特性、异步编程、模块化等高级概念。</p>
                    <div class="course-meta">
                        <span><i class="far fa-clock"></i> 12小时</span>
                        <span><i class="far fa-calendar"></i> 上次学习: 2天前</span>
                    </div>
                    <div class="course-actions">
                        <a href="#" class="btn btn-primary">继续学习</a>
                        <button class="btn btn-secondary"><i class="far fa-bookmark"></i></button>
                    </div>
                </div>
            </div>

            <!-- 课程卡片 2 -->
            <div class="course-card">
                <div class="course-image">
                    <img src="https://placehold.co/300x160/21262d/8b949e?text=JavaScript" alt="JavaScript 高级编程">
                    <div class="course-category">数据科学</div>
                    <div class="course-progress">
                        <div class="progress-bar" style="width: 30%"></div>
                    </div>
                </div>
                <div class="course-content">
                    <h3 class="course-title">Python 数据分析</h3>
                    <p class="course-description">使用Pandas、NumPy和Matplotlib进行数据清洗、分析和可视化。</p>
                    <div class="course-meta">
                        <span><i class="far fa-clock"></i> 18小时</span>
                        <span><i class="far fa-calendar"></i> 上次学习: 1周前</span>
                    </div>
                    <div class="course-actions">
                        <a href="#" class="btn btn-primary">继续学习</a>
                        <button class="btn btn-secondary"><i class="far fa-bookmark"></i></button>
                    </div>
                </div>
            </div>

            <!-- 课程卡片 3 -->
            <div class="course-card">
                <div class="course-image">
                    <img src="https://placehold.co/300x160/21262d/8b949e?text=JavaScript" alt="JavaScript 高级编程">
                    <div class="course-category">后端开发</div>
                    <div class="course-progress">
                        <div class="progress-bar" style="width: 100%"></div>
                    </div>
                </div>
                <div class="course-content">
                    <h3 class="course-title">Node.js 与 Express</h3>
                    <p class="course-description">构建快速、可扩展的Web应用程序和API，使用现代JavaScript技术栈。</p>
                    <div class="course-meta">
                        <span><i class="far fa-clock"></i> 15小时</span>
                        <span><i class="fas fa-check-circle" style="color: var(--success-color);"></i> 已完成</span>
                    </div>
                    <div class="course-actions">
                        <a href="#" class="btn btn-primary">查看证书</a>
                        <button class="btn btn-secondary"><i class="fas fa-bookmark"></i></button>
                    </div>
                </div>
            </div>

            <!-- 课程卡片 4 -->
            <div class="course-card">
                <div class="course-image">
                    <img src="https://placehold.co/300x160/21262d/8b949e?text=JavaScript" alt="JavaScript 高级编程">
                    <div class="course-category">UI/UX设计</div>
                    <div class="course-progress">
                        <div class="progress-bar" style="width: 0%"></div>
                    </div>
                </div>
                <div class="course-content">
                    <h3 class="course-title">Figma 设计入门</h3>
                    <p class="course-description">学习使用Figma进行界面设计、原型制作和团队协作。</p>
                    <div class="course-meta">
                        <span><i class="far fa-clock"></i> 8小时</span>
                        <span><i class="far fa-calendar"></i> 尚未开始</span>
                    </div>
                    <div class="course-actions">
                        <a href="#" class="btn btn-primary">开始学习</a>
                        <button class="btn btn-secondary"><i class="far fa-bookmark"></i></button>
                    </div>
                </div>
            </div>

            <!-- 课程卡片 5 -->
            <div class="course-card">
                <div class="course-image">
                    <img src="https://placehold.co/300x160/21262d/8b949e?text=JavaScript" alt="JavaScript 高级编程">
                    <div class="course-category">DevOps</div>
                    <div class="course-progress">
                        <div class="progress-bar" style="width: 45%"></div>
                    </div>
                </div>
                <div class="course-content">
                    <h3 class="course-title">Docker 与容器化</h3>
                    <p class="course-description">掌握Docker容器技术，实现应用程序的快速部署和扩展。</p>
                    <div class="course-meta">
                        <span><i class="far fa-clock"></i> 10小时</span>
                        <span><i class="far fa-calendar"></i> 上次学习: 3天前</span>
                    </div>
                    <div class="course-actions">
                        <a href="#" class="btn btn-primary">继续学习</a>
                        <button class="btn btn-secondary"><i class="far fa-bookmark"></i></button>
                    </div>
                </div>
            </div>

            <!-- 课程卡片 6 -->
            <div class="course-card">
                <div class="course-image">
                    <img src="https://placehold.co/300x160/21262d/8b949e?text=JavaScript" alt="JavaScript 高级编程">
                    <div class="course-category">移动开发</div>
                    <div class="course-progress">
                        <div class="progress-bar" style="width: 80%"></div>
                    </div>
                </div>
                <div class="course-content">
                    <h3 class="course-title">React Native 开发</h3>
                    <p class="course-description">使用React Native构建跨平台移动应用程序，一次编写，多端运行。</p>
                    <div class="course-meta">
                        <span><i class="far fa-clock"></i> 20小时</span>
                        <span><i class="far fa-calendar"></i> 上次学习: 昨天</span>
                    </div>
                    <div class="course-actions">
                        <a href="#" class="btn btn-primary">继续学习</a>
                        <button class="btn btn-secondary"><i class="fas fa-bookmark"></i></button>
                    </div>
                </div>
            </div>
        </div>
    </main>

    <!-- 页脚 -->
    <footer>
        <div class="container">
            <p>© 2023 StudyRaid. 保留所有权利。</p>
            <p>采用 GitHub 深色风格设计</p>
        </div>
    </footer>

    <script>
        // 筛选按钮交互
        document.querySelectorAll('.filter-btn').forEach(button => {
            button.addEventListener('click', function () {
                document.querySelectorAll('.filter-btn').forEach(btn => {
                    btn.classList.remove('active');
                });
                this.classList.add('active');

                // 这里可以添加筛选课程的逻辑
                console.log(`筛选条件: ${this.textContent}`);
            });
        });

        // 收藏按钮交互
        document.querySelectorAll('.btn-secondary').forEach(button => {
            button.addEventListener('click', function () {
                const icon = this.querySelector('i');
                if (icon.classList.contains('far')) {
                    icon.classList.remove('far');
                    icon.classList.add('fas');
                    this.style.color = 'var(--accent-color)';
                } else {
                    icon.classList.remove('fas');
                    icon.classList.add('far');
                    this.style.color = '';
                }
            });
        });

        // 搜索功能
        const searchInput = document.querySelector('.search-box input');
        searchInput.addEventListener('input', function () {
            const searchTerm = this.value.toLowerCase();
            const courseCards = document.querySelectorAll('.course-card');

            courseCards.forEach(card => {
                const title = card.querySelector('.course-title').textContent.toLowerCase();
                const description = card.querySelector('.course-description').textContent.toLowerCase();

                if (title.includes(searchTerm) || description.includes(searchTerm)) {
                    card.style.display = 'block';
                } else {
                    card.style.display = 'none';
                }
            });
        });
    </script>
</body>

</html>